/*
 * To change this license header, choose License Headers in Project Properties.
 * To change this template file, choose Tools | Templates
 * and open the template in the editor.
 */
package com.soa.service.busi.wx;

import com.lianzt.commondata.AbstractCommonData;
import com.soa.exception.GlobalException;
import com.soa.service.BaseService;
import com.soa.util.SystemUtil;
import org.springframework.stereotype.Service;

/**
 *  P90011
 * 保存日常花销
 * @author chang
 */
@Service
public class SaveRchx extends BaseService{

    @Override
    public String[] keys() {
        return null;
    }

    @Override
    public void execute(AbstractCommonData in, AbstractCommonData inhead, AbstractCommonData out, AbstractCommonData outhead) {
        String userid = getSession(in).getStringValue("userid");
        String id  = SystemUtil.getSerialNum();
        String gd = in.getStringValue("gd");
        String fy = in.getStringValue("fy");
        String kzrq = in.getStringValue("kzrq");
        String hxxm = in.getStringValue("hxxm");
        String hxyt = in.getStringValue("hxyt");
        try {
            update("insert_shkz", new Object[]{id,gd,hxxm,hxyt,fy,kzrq,userid});
        } catch (Exception e) {
            throw new GlobalException(9001101,e);
        }
    }
    
}
